Embodiments of the present invention relate to in general to databases, and in particular to techniques for aiding a user in tuning database performance by recommending parallel execution of SQL statements.
Several current relational database management systems (RDBMSs) support the parallel execution of SQL statements. Generally speaking, when a SQL statement is executed in parallel by a database server, the work necessary for running the statement is divided among two or more processes or microprocessors (e.g., CPUs) of the server. This can, in some instances, significantly reduce the execution elapsed time (and thus, response time) for the statement when compared with serial execution.
However, not all SQL statements are well-suited for parallel execution. Parallel processing has a performance overhead, which can in turn affect a database server's throughput and the response time of other concurrent statements/queries. Thus, for certain SQL statements and certain contexts, parallel execution can have an ineffective (or even detrimental) performance impact. Unfortunately, there is currently no automated mechanism for aiding a user (e.g., a database administrator (DBA)) in determining whether a particular SQL statement can benefit from being run in parallel.